#ifndef FIELD_H
#define FIELD_H

#include <iostream>
#include "Debug.h"

// TODO find a better place.
enum Player {
	Player1 = 0,
	Player2 = 1,
	None	= -1,
	Unavailable = -2,
	OffBoard = -3
};


// TODO Make occupyer a Piece class.

class Field {
public:
	/** \brief Create an empty field.
	*/
	Field();

	Field( Field &rhs );

	/** \brief Creates a field
	Creates a field with selected occupancy.
	@param[in] occupancy The current occupancy, 0 for player 1, 1 for player 2, -1 for empty.
	*/
	Field(int occupancy) : m_occupyer(occupancy) {};

	~Field(void);

	/** \brief Set the occupancy
	@param[in] player Sets the current occupancy to player.
	*/
	void setOccupancy( int player );

	/** \brief Returns the current occupancy of the field.
	*/
	int getOccupancy() { return m_occupyer; };

	Field& operator=( Field &rhs );

private:
	int m_occupyer; /**< Current occupyer, 0 Player1, 1 Player 2, -1 No one */
	Debug* debugger;	
};

#endif // FIELD_H
